home *** CD-ROM | disk | FTP | other *** search
/ United Public Domain Gold 2 / United Public Domain Gold 2.iso / utilities / pu399.dms / pu399.adf / Documentation / 68040_Notes < prev    next >
Text File  |  1994-11-01  |  3KB  |  55 lines

  1.  
  2.                                 A.I.B.B.
  3.                     Amiga Intuition Based Benchmarks
  4.                        Program Release Version 6.0
  5.                     Copyright 1991-1993 LaMonte Koop
  6.  
  7.                            MC68040 Users Notes
  8.  
  9.      The Motorola MC68040 microprocessor, newest of the M680x0 series, is of
  10. recent times seeing more use in various Amiga platforms.  The 68040 is
  11. a very versatile and quite advanced unit, capable of outperforming the earlier
  12. M680x0 series microprocessors by great lengths.  However, as with any
  13. advanced processing unit as such, the greatest performance benefit is seen
  14. when it is operating with code fine-tuned for it specifically.  This can be
  15. most easily seen with the 68040 in terms of floating-point operations.
  16.      The MC68040 contains a specialized floating point unit ( FPU )
  17. internally, as opposed to such a unit being interfaced externally such as
  18. the MC68030 and an MC68881 or MC68882 floating-point coprocessor.  The FPU
  19. within the 68040 is basically a fine-tuned sub-unit of the MC68882.  It
  20. supports the basic floating-point multiplication, division, addition, and
  21. subtraction functions, as well as some of the other less complicated
  22. operations.  Unlike the MC68882 and MC68881 however, the complex
  23. transcendental functions, such as sine, cosine, log functions, etc..., are
  24. not hardware microcoded, and thus must be software emulated.
  25.      In order to maintain object code compatibility with the MC68881 and
  26. MC68882, emulation packages for the transcendental functions and other
  27. missing elements in the 68040 FPU have been developed for use.  What these
  28. packages do is perform the function desired and return the result once the
  29. 68040 take an unimplemented instruction exception upon encountering an
  30. FPU call which is not included in this processor's FPU.  This allows for
  31. code previously utilized with the MC68881 and MC68882 to operate normally
  32. with this processor, but it does contain a disadvantage.
  33.      When the 68040 takes the aformentioned exception trap, there is a
  34. fair amount of CPU overhead involved.  The current processor state must
  35. be saved, and then the proper exception vector taken, which leads to the
  36. emulated software function.  All of this takes time, and in a code segment
  37. having many calls to such unimplemented functions in the 68040, this can
  38. lead to a somewhat noticable slowdown as compared to a straight MC68881 or
  39. MC68882 interface on an earlier CPU.  Despite this, let it not be thought
  40. that the FPU on the 68040 is unusable for such features.
  41.      The instruction set supported by the built-in 68040 FPU is in fact
  42. very fine-tuned, with such instructions being performed much faster than on
  43. either the MC68881 or MC68882.  Code specifically designed for the 68040
  44. can take advantage of this by 'building' the transcendental functions out
  45. of the existing functions ( the supported functions are in fact the building
  46. blocks necessary for this ).  Such functions designed this way, as either
  47. a subroutine call or in-line code, will in fact execute FASTER than the
  48. hardware supported MC68881 or MC68882 versions.
  49.      AIBB includes options for both 68881/68882 inline code, and 68040
  50. optimized inline code for floating-point tests.  The 68040 optimized test
  51. code should be used whenever possible when operating on a 68040, but
  52. to get a feel for how more 'common' code, which is designed for the
  53. 68881/68882, would function, feel free to use the standard coprocessor
  54. code options.
  55.